import Vue from 'vue';
import Router from 'vue-router';
import Login from '../components/Login.vue';
import Register from '../components/Register.vue';
import Main from '../components/Main.vue';
import Data from '../components/Data.vue';
import Order from '../components/Order.vue';
import Type from '../components/Type.vue';
import Food from '../components/Food.vue';
import Store from '../components/Store.vue';
import Application from '../components/Application.vue';
import Audit from '../components/Audit.vue';
import Comment from '../components/Comment.vue';
import Registerform from '../components/Registerform.vue';
import UpdateRegisterform from '../components/UpdateRegisterform.vue';



Vue.use(Router)

export default new Router({
  routes: [
   {
     path: '/',
     component: Login,
   },
   {
     path: '/login',
     component: Login,
   },
   {
     path: '/register',
     component: Register,
   },
   {
     path: '/main',
     component: Main,

     children: [
       {
         path: '/order',
         component: Order,
       },
       {
         path: '/data',
         component: Data,
       },
       {
         path: '/type',
         component: Type,
       },
       {
         path: '/food',
         component: Food,
       },
       {
         path: '/audit',
         component: Audit,
       },
       {
         path: '/store',
         component: Store,
       },
       {
         path: '/application',
         component: Application,
       },
       {
         path: '/comment',
         component: Comment,
       },
       {
         path: '/registerform',
         component: Registerform,
       },
       {
         path: '/updateRegisterform',
         component: UpdateRegisterform,
       }
     ]
   },
  ]
})
